package com.java.core1.chapter3;

import java.io.Console;

/**
 * @author ClearScenery
 * @version 创建时间：2019年3月29日 下午4:10:02
 * @ClassName ScannerTest2
 * @Description
 */
public class ScannerTest2 {
	public static void main(String[] args) {
		System.out.print("sssssssssssssss");
		Console cnsl = System.console();
		
	    if (cnsl != null) {

	      String alpha = cnsl.readLine("Name: ");

	      System.out.println("Name is: " + alpha);

	      char[] pwd = cnsl.readPassword("Password: ");

	      System.out.println("Password is: " + pwd);
	    }

	}
}
